package b3.widget.home.top
{
	import b3.model.*;
	import b3.net.*;
	import b3.scene.home.*;
	import b3.widget.*;
	import b3.widget.basic.*;
	import b3.widget.guild.*;
	import b3.widget.store.*;
	
	import flash.events.MouseEvent;
	
	public class UnionIcon extends BasicIcon
	{
		public function UnionIcon()
		{
			var IconBgr:Class = ResourceHelper.getInstance().getClassByName("UnionIcon");
			super(IconBgr, "联盟", 1, true);
			addEventListener(MouseEvent.CLICK, onMouseClick);
		}
		
		private function onMouseClick(event:MouseEvent):void
		{
//			var popMessage:PopMessage = new PopMessage("尚未开启，敬请期待！", 0xFF0000);
//			WidgetManager.getInstance().popOut([popMessage]);
			if (HomeScene.getInstance().getOperationMode() == HomeScene.NONEMODE)
			{
				var guildDialog:GuildDialog = new GuildDialog();
				guildDialog.x = -guildDialog.width / 2;
				guildDialog.y = -guildDialog.height / 2;
				WidgetManager.getInstance().popOut([guildDialog], true);
			}
		}
	}
}